#include "ColorComboxPlugin.h"
#include "ColorCombox.h"
#include <QtCore/QtPlugin>
ColorComboxPluginDesigner::ColorComboxPluginDesigner(QObject* parent)
    : QObject(parent)
{
    initialized = false;
}

void ColorComboxPluginDesigner::initialize(QDesignerFormEditorInterface* /*core*/)
{
    if (initialized)
        return;

    initialized = true;
}

bool ColorComboxPluginDesigner::isInitialized() const
{
    return initialized;
}

QWidget* ColorComboxPluginDesigner::createWidget(QWidget* parent)
{
    return new ColorComboBox(parent);
}

QString ColorComboxPluginDesigner::name() const
{
    return "ColorComboxPluginDesigner";
}

QString ColorComboxPluginDesigner::group() const
{
    return "My Plugins";
}

QIcon ColorComboxPluginDesigner::icon() const
{
    return QIcon();
}

QString ColorComboxPluginDesigner::toolTip() const
{
    return QString();
}

QString ColorComboxPluginDesigner::whatsThis() const
{
    return QString();
}

bool ColorComboxPluginDesigner::isContainer() const
{
    return false;
}

QString ColorComboxPluginDesigner::domXml() const
{
    return "<widget class=\"ColorCombox\" name=\"ColorCombox\">\n"
        " <property name=\"geometry\">\n"
        "  <rect>\n"
        "   <x>0</x>\n"
        "   <y>0</y>\n"
        "   <width>100</width>\n"
        "   <height>50</height>\n"
        "  </rect>\n"
        " </property>\n"
        "</widget>\n";
}

QString ColorComboxPluginDesigner::includeFile() const
{
    return "ColorCombox.h";
}